import "./public-path";
import { createApp } from "vue";
import App from "./App.vue";
import router from "./router";
import store from "./store";
import ElementPlus from "element-plus";
import * as ElementPlusIconsVue from "@element-plus/icons-vue";
import "element-plus/dist/index.css";
import zhCn from "element-plus/dist/locale/zh-cn.mjs";
import "@/assets/styles/transition.css";
import "@/assets/styles/index.css";
import "@/assets/styles/index.scss";
import "@/assets/iconfont/iconfont.css";

import components from "@/components";
import piniaPersist from "pinia-plugin-persist";
import "@/router/permission";
store.use(piniaPersist);
import plugins from "./plugins";
import install from "./directives";

const app = createApp(App);
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component);
}
app.use(router).use(ElementPlus, { locale: zhCn }).use(store).use(plugins).use(components).use(install).mount("#designer-app");
